<?xml version="1.0" encoding="iso-8859-1" standalone="no"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content=
    "application/xhtml+xml; charset=iso-8859-1" />
    <title>
      fftw-3.3.8
    </title>
    <link rel="stylesheet" type="text/css" href="../stylesheets/lfs.css" />
    <meta name="generator" content="DocBook XSL Stylesheets V1.79.1" />
    <link rel="stylesheet" href="../stylesheets/lfs-print.css" type=
    "text/css" media="print" />
  </head>
  <body class="blfs" id="blfs-9.1">
    <div class="navheader">
      <h4>
        Beyond Linux<sup>�</sup> From Scratch <span class="phrase">(System
        V</span> Edition) - Version 9.1
      </h4>
      <h3>
        Chapter&nbsp;9.&nbsp;General Libraries
      </h3>
      <ul>
        <li class="prev">
          <a accesskey="p" href="exempi.html" title="Exempi-2.5.1">Prev</a>
          <p>
            Exempi-2.5.1
          </p>
        </li>
        <li class="next">
          <a accesskey="n" href="glib2.html" title="GLib-2.62.4">Next</a>
          <p>
            GLib-2.62.4
          </p>
        </li>
        <li class="up">
          <a accesskey="u" href="genlib.html" title=
          "Chapter&nbsp;9.&nbsp;General Libraries">Up</a>
        </li>
        <li class="home">
          <a accesskey="h" href="../index.html" title=
          "Beyond Linux� From Scratch     (System V Edition) - Version 9.1">Home</a>
        </li>
      </ul>
    </div>
    <div class="sect1" lang="en" xml:lang="en">
      <h1 class="sect1">
        <a id="fftw" name="fftw"></a>fftw-3.3.8
      </h1>
      <div class="package" lang="en" xml:lang="en">
        <h2 class="sect2">
          Introduction to fftw
        </h2>
        <p>
          FFTW is a C subroutine library for computing the discrete Fourier
          transform (DFT) in one or more dimensions, of arbitrary input size,
          and of both real and complex data (as well as of even/odd data,
          i.e. the discrete cosine/sine transforms or DCT/DST).
        </p>
        <p>
          This package is known to build and work properly using an LFS-9.1
          platform.
        </p>
        <h3>
          Package Information
        </h3>
        <div class="itemizedlist">
          <ul class="compact">
            <li class="listitem">
              <p>
                Download (HTTP): <a class="ulink" href=
                "http://www.fftw.org/fftw-3.3.8.tar.gz">http://www.fftw.org/fftw-3.3.8.tar.gz</a>
              </p>
            </li>
            <li class="listitem">
              <p>
                Download (FTP): <a class="ulink" href=
                "ftp://ftp.fftw.org/pub/fftw/fftw-3.3.8.tar.gz">ftp://ftp.fftw.org/pub/fftw/fftw-3.3.8.tar.gz</a>
              </p>
            </li>
            <li class="listitem">
              <p>
                Download MD5 sum: 8aac833c943d8e90d51b697b27d4384d
              </p>
            </li>
            <li class="listitem">
              <p>
                Download size: 3.9 MB
              </p>
            </li>
            <li class="listitem">
              <p>
                Estimated disk space required: 57 MB (add 1 MB for tests)
              </p>
            </li>
            <li class="listitem">
              <p>
                Estimated build time: 1.6 SBU (using parallelism=4; add 1.9
                SBU for tests)
              </p>
            </li>
          </ul>
        </div>
        <p class="usernotes">
          User Notes: <a class="ulink" href=
          "http://wiki.linuxfromscratch.org/blfs/wiki/fftw">http://wiki.linuxfromscratch.org/blfs/wiki/fftw</a>
        </p>
      </div>
      <div class="installation" lang="en" xml:lang="en">
        <h2 class="sect2">
          Installation of fftw
        </h2>
        <div class="admon note">
          <img alt="[Note]" src="../images/note.png" />
          <h3>
            Note
          </h3>
          <p>
            We build fftw three times for different libraries in different
            numerical precisions: the default double precision floating
            point, the older 32-bit (single precision) version named float
            which sacrifices precision for speed, and the long double which
            offers increased precision at the cost of slower execution.
          </p>
        </div>
        <p>
          The first build is for double precision arithmetic. Install
          <span class="application">fftw</span> by running the following
          commands:
        </p>
        <pre class="userinput">
<kbd class="command">./configure --prefix=/usr    \
            --enable-shared  \
            --enable-threads \
            --enable-sse2    \
            --enable-avx     &amp;&amp;
make</kbd>
</pre>
        <p>
          To test the results, issue: <span class="command"><strong>make
          check</strong></span>. On 32-bit systems, the tests can take
          substantially longer than they would on 64-bit machines.
        </p>
        <p>
          Now, as the <code class="systemitem">root</code> user:
        </p>
        <pre class="root">
<kbd class="command">make install</kbd>
</pre>
        <p>
          Now build single precision:
        </p>
        <pre class="userinput">
<kbd class="command">make clean &amp;&amp;

./configure --prefix=/usr    \
            --enable-shared  \
            --enable-threads \
            --enable-sse2    \
            --enable-avx     \
            --enable-float   &amp;&amp;
make</kbd>
</pre>
        <p>
          As the <code class="systemitem">root</code> user:
        </p>
        <pre class="root">
<kbd class="command">make install</kbd>
</pre>
        <p>
          Finally, build long double precision:
        </p>
        <pre class="userinput">
<kbd class="command">make clean &amp;&amp;

./configure --prefix=/usr    \
            --enable-shared  \
            --enable-threads \
            --enable-long-double &amp;&amp;
make</kbd>
</pre>
        <p>
          As the <code class="systemitem">root</code> user:
        </p>
        <pre class="root">
<kbd class="command">make install</kbd>
</pre>
      </div>
      <div class="commands" lang="en" xml:lang="en">
        <h2 class="sect2">
          Command Explanations
        </h2>
        <p>
          <em class="parameter"><code>--enable-shared</code></em>: Use shared
          libs instead of static libs.
        </p>
        <p>
          <em class="parameter"><code>--enable-threads</code></em>: This
          enables <code class="filename">libfftw3_threads.so</code> to be
          compiled. It is used by e.g. the <span class=
          "application">gimp</span> plugin from <a class="ulink" href=
          "http://gmic.eu/">G'MIC</a>.
        </p>
        <p>
          <em class="parameter"><code>--enable-float</code></em>: This
          enables building the library that uses single precision floating
          point arithmetic. It is faster but less precise than the default
          double precision library. The library will be called <code class=
          "filename">libfftw3f.so</code> needed by <a class="xref" href=
          "../multimedia/pulseaudio.html" title=
          "PulseAudio-13.0">PulseAudio-13.0</a>.
        </p>
        <p>
          <em class="parameter"><code>--enable-long-double</code></em>: This
          enables building the library that uses higher precision long-double
          floating point arithmetic. The library will be called <code class=
          "filename">libfftw3l.so</code>.
        </p>
      </div>
      <div class="content" lang="en" xml:lang="en">
        <h2 class="sect2">
          Contents
        </h2>
        <div class="segmentedlist">
          <div class="seglistitem">
            <div class="seg">
              <strong class="segtitle">Installed Programs:</strong>
              <span class="segbody">fftw-wisdom and
              fftw-wisdom-to-conf</span>
            </div>
            <div class="seg">
              <strong class="segtitle">Installed Libraries:</strong>
              <span class="segbody">libfftw3.so, libfftw3_threads.so,
              libfftw3f.so, libfftw3f_threads.so, libfftw3l.so and
              libfftw3l_threads.so</span>
            </div>
            <div class="seg">
              <strong class="segtitle">Installed Directories:</strong>
              <span class="segbody">None</span>
            </div>
          </div>
        </div>
        <div class="variablelist">
          <h3>
            Short Descriptions
          </h3>
          <table border="0" class="variablelist">
            <colgroup>
              <col align="left" valign="top" />
              <col />
            </colgroup>
            <tbody>
              <tr>
                <td>
                  <p>
                    <a id="fftw-wisdom" name="fftw-wisdom"></a><span class=
                    "term"><span class=
                    "command"><strong>fftw-wisdom</strong></span></span>
                  </p>
                </td>
                <td>
                  <p>
                    is a utility to generate FFTW wisdom files, which contain
                    saved information about how to optimally compute
                    (Fourier) transforms of various sizes.
                  </p>
                </td>
              </tr>
              <tr>
                <td>
                  <p>
                    <a id="fftw-wisdom-to-conf" name=
                    "fftw-wisdom-to-conf"></a><span class="term"><span class=
                    "command"><strong>fftw-wisdom-to-conf</strong></span></span>
                  </p>
                </td>
                <td>
                  <p>
                    is a utility to generate C configuration routines from
                    FFTW wisdom files, where the latter contain saved
                    information about how to optimally compute (Fourier)
                    transforms of various sizes.
                  </p>
                </td>
              </tr>
              <tr>
                <td>
                  <p>
                    <a id="libfftw3" name="libfftw3"></a><span class=
                    "term"><code class="filename">libfftw3.so</code></span>
                  </p>
                </td>
                <td>
                  <p>
                    is the Fast Fourier Transform library
                  </p>
                </td>
              </tr>
              <tr>
                <td>
                  <p>
                    <a id="libfftw3_threads" name=
                    "libfftw3_threads"></a><span class="term"><code class=
                    "filename">libfftw3_threads.so</code></span>
                  </p>
                </td>
                <td>
                  <p>
                    is the threaded Fast Fourier Transform library
                  </p>
                </td>
              </tr>
              <tr>
                <td>
                  <p>
                    <a id="libfftw3f" name="libfftw3f"></a><span class=
                    "term"><code class="filename">libfftw3f.so</code></span>
                  </p>
                </td>
                <td>
                  <p>
                    is the single-precision Fast Fourier Transform library,
                    described as 'float' for historic reasons
                  </p>
                </td>
              </tr>
              <tr>
                <td>
                  <p>
                    <a id="libfftw3f_threads" name=
                    "libfftw3f_threads"></a><span class="term"><code class=
                    "filename">libfftw3f_threads.so</code></span>
                  </p>
                </td>
                <td>
                  <p>
                    is the threaded single-precision Fast Fourier Transform
                    library
                  </p>
                </td>
              </tr>
              <tr>
                <td>
                  <p>
                    <a id="libfftw3l" name="libfftw3l"></a><span class=
                    "term"><code class="filename">libfftw3l.so</code></span>
                  </p>
                </td>
                <td>
                  <p>
                    is the long double Fast Fourier Transform library
                  </p>
                </td>
              </tr>
              <tr>
                <td>
                  <p>
                    <a id="libfftw3l_threads" name=
                    "libfftw3l_threads"></a><span class="term"><code class=
                    "filename">libfftw3l_threads.so</code></span>
                  </p>
                </td>
                <td>
                  <p>
                    is the threaded long double Fast Fourier Transform
                    library
                  </p>
                </td>
              </tr>
            </tbody>
          </table>
        </div>
      </div>
      <p class="updated">
        Last updated on 2020-02-16 18:46:23 -0800
      </p>
    </div>
    <div class="navfooter">
      <ul>
        <li class="prev">
          <a accesskey="p" href="exempi.html" title="Exempi-2.5.1">Prev</a>
          <p>
            Exempi-2.5.1
          </p>
        </li>
        <li class="next">
          <a accesskey="n" href="glib2.html" title="GLib-2.62.4">Next</a>
          <p>
            GLib-2.62.4
          </p>
        </li>
        <li class="up">
          <a accesskey="u" href="genlib.html" title=
          "Chapter&nbsp;9.&nbsp;General Libraries">Up</a>
        </li>
        <li class="home">
          <a accesskey="h" href="../index.html" title=
          "Beyond Linux� From Scratch     (System V Edition) - Version 9.1">Home</a>
        </li>
      </ul>
    </div>
  </body>
</html>
